<script setup lang="ts">
import zhCN from 'ant-design-vue/es/locale/zh_CN';

import sideBar from '@/views/menu/SideBar.vue'
import headerBar from '@/views/menu/HeaderBar.vue'
import footerBar from '@/views/menu/FooterBar.vue'
import mainPane from '@/views/menu/MainPane.vue'
import login from '@/views/page/loginPage.vue'

import useBaseStore from '@/stores/baseStore.ts'

const baseStore = useBaseStore();
const content = "GTenACGN          By: dusqs            Gitee: https://gitee.com/dusqs "

</script>

<template>
	<!-- 全局配置 -->
	<a-config-provider :locale="zhCN">
		<a-watermark :content="content" style="height: 100%;">

			<!-- 登录页面 -->
			<login v-if="!baseStore.isLogin" />

			<!-- 内容页码 -->
			<a-layout style="min-height: 100vh;" v-if="baseStore.isLogin">

				<!-- 侧边栏 -->
				<sideBar />

				<a-layout>
					<headerBar />

					<div style="width: 100%;overflow-y: auto;height: 90vh;">
						<mainPane />

						<footerBar />
					</div>

				</a-layout>
			</a-layout>
			
		</a-watermark>

	</a-config-provider>
</template>
